<?php
namespace PAT\UserBundle\Form\Type;

use Symfony\Component\Form\FormBuilderInterface;
use FOS\UserBundle\Form\Type\ProfileFormType as BaseType;

class ProfileFormType extends BaseType
{
	public function buildForm(FormBuilderInterface $builder, array $options)
	{
		parent::buildForm($builder, $options);

		$builder->add('name');
		$builder->add('firstname');
		$builder->add('telephone');
		$builder->add('addresses','collection',
				array('type' => new AddressType(),
						'prototype' => true,//bof
						'allow_add' => true,
						'allow_delete' => true,
						'by_reference' => false,
						'label' => 'maistkitoi'));
	}

	public function getName()
	{
		return 'pat_user_edit';
	}
}